package com.xudow.app.model;

import java.util.List;

/**购物车Item实体
 * 作者：zhouXJ on 2016/4/29 10:37
 */
public class CartModle {
    public Long schoolId; //学校Id
    public String schoolName; //校区名称
    public String userSendAddress;
    public String userSendSchoolName;
    public String agencyNmae; //教育单位名称
    public boolean isSelect=false;  //是否选择
    public String schoolImag; //学校图片
    public boolean hasTicket; //是否有劵可领
    public String teacher;
    public Long sendlocid;//发布者Id
    public long itemId;
    public List<Coures> couresList; //学校对应课程列表


    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result
                + ((agencyNmae == null) ? 0 : agencyNmae.hashCode());
        result = prime * result + (int) (schoolId ^ (schoolId >>> 32));
        result = prime * result
                + ((schoolName == null) ? 0 : schoolName.hashCode());
        return result;
    }
    @Override
    public boolean equals(Object obj) {
        if (this == obj)
            return true;
        if (obj == null)
            return false;
        if (getClass() != obj.getClass())
            return false;
        CartModle other = (CartModle) obj;
        if (agencyNmae == null) {
            if (other.agencyNmae != null)
                return false;
        } else if (!agencyNmae.equals(other.agencyNmae))
            return false;
        if (schoolId != other.schoolId)
            return false;
        if (schoolName == null) {
            if (other.schoolName != null)
                return false;
        } else if (!schoolName.equals(other.schoolName))
            return false;
        return true;
    }
}
